home *** CD-ROM | disk | FTP | other *** search
- //=--------------------------------------------------------------------------=
- // ObjSafe.h
- //=--------------------------------------------------------------------------=
- // (C) Copyright 1995-1996 Microsoft Corporation. All Rights Reserved.
- // Delphi translation by Dan Miser - 5/30/97
- unit ObjSafe;
-
- interface
-
- uses
- Windows;
-
- //=--------------------------------------------------------------------------=
- //
- // Contents: IObjectSafety definition
- //
- //
- // IObjectSafety should be implemented by objects that have interfaces which
- // support "untrusted" clients (for example, scripts). It allows the owner of
- // the object to specify which interfaces need to be protected from untrusted
- // use. Examples of interfaces that might be protected in this way are:
- //
- // IID_IDispatch - "Safe for automating with untrusted automation client or script"
- // IID_IPersist* - "Safe for initializing with untrusted data"
- // IID_IActiveScript - "Safe for running untrusted scripts"
- //
- //---------------------------------------------------------------------------=
- type
- {IObjectSafety interface}
- IObjectSafety = interface(IUnknown)
- ['{CB5BDC81-93C1-11cf-8F20-00805F2CD064}']
- function GetInterfaceSafetyOptions(const riid: TGUID;
- out pdwSupportedOptions: DWORD; out pdwEnabledOptions: DWORD) : HResult; stdcall;
- function SetInterfaceSafetyOptions(const riid : TGUID;
- const dwOptionSetMask: DWORD; const dwEnabledOptions: DWORD) : HResult; stdcall;
- end;
-
- // Option bit definitions for IObjectSafety:
- const
- INTERFACESAFE_FOR_UNTRUSTED_CALLER = 1; // Caller of interface may be untrusted
- INTERFACESAFE_FOR_UNTRUSTED_DATA = 2; // Data passed into interface may be untrusted
-
- IID_IObjectSafety : TGUID = (
- D1:$cb5bdc81;D2:$93c1;D3:$11cf;D4:($8f,$20,$00,$80,$5f,$2c,$d0,$64));
-
- const
- CATID_SafeForScripting: TGUID = '{7DD95801-9882-11CF-9FA9-00AA006C42C4}';
- CATID_SafeForInitializing: TGUID = '{7DD95802-9882-11CF-9FA9-00AA006C42C4}';
-
- implementation
-
- end.
-